<template>
  <div id="app">
    <router-view />
  </div>
</template>

<script setup>
import { onMounted } from 'vue'
import { useStore } from 'vuex'
import { getToken } from '@ruifox-cms/utils/src/storage'

const store = useStore()
onMounted(async () => {
  if (getToken()) {
    const { iconInit } = await import('@ruifox-cms/utils')
    const res = await store.dispatch('base/getGroupSetting')
    iconInit(res.publicIcon)
  }
})
</script>

<style lang="scss">
#app {
  width: 100vw;
  height: 100vh;
  overflow-y: hidden;
}
</style>
